package com.norteksoft.erm.model;

import java.util.Set;
import org.apache.commons.lang.builder.HashCodeBuilder;

/**
 * 部门等级
 * 
 * @hibernate.class table="ERM_GROUP_LEVEL"
 */

public class GroupLevel extends BaseObject {

	private Long OID = new Long(-1);// OID

	private String name;// 等级名称

	private String code;// 等级编号

	private Integer level;// 等级

	private Set myGroups;

	public int hashCode() {
		return new HashCodeBuilder().append(OID).append(name).append(code)
				.append(level).toHashCode();
	}

	/**
	 * @hibernate.id column="OID" unsaved-value="-1" type="long"
	 * @hibernate.generator class="sequence"
	 * @hibernate.param name="sequence" value="ERM_SEQUENCE"
	 */

	public Long getOID() {
		return OID;
	}

	public void setOID(Long oid) {
		OID = oid;
	}

	/**
	 * @hibernate.property column="NAME" length="60" type="string"
	 *                     not-null="true"
	 * @return String
	 */
	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	/**
	 * @hibernate.property column="CODE" length="100" type="string"
	 *                     not-null="true"
	 * @return String
	 */
	public String getCode() {
		return code;
	}

	public void setCode(String code) {
		this.code = code;
	}

	/**
	 * @hibernate.property column="LEVEL" type="integer" not-null="true"
	 * @return String
	 */
	public Integer getLevel() {
		return level;
	}

	public void setLevel(Integer level) {
		this.level = level;
	}

	public Set getMyGroups() {
		return myGroups;
	}

	public void setMyGroups(Set myGroups) {
		this.myGroups = myGroups;
	}

}
